// Licensed to Elasticsearch B.V under one or more agreements.
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
// See the LICENSE file in the project root for more information.
//
// ███╗   ██╗ ██████╗ ████████╗██╗ ██████╗███████╗
// ████╗  ██║██╔═══██╗╚══██╔══╝██║██╔════╝██╔════╝
// ██╔██╗ ██║██║   ██║   ██║   ██║██║     █████╗
// ██║╚██╗██║██║   ██║   ██║   ██║██║     ██╔══╝
// ██║ ╚████║╚██████╔╝   ██║   ██║╚██████╗███████╗
// ╚═╝  ╚═══╝ ╚═════╝    ╚═╝   ╚═╝ ╚═════╝╚══════╝
// ------------------------------------------------
//
// This file is automatically generated.
// Please do not edit these files manually.
//
// ------------------------------------------------

using Elastic.Transport;
using System;
using System.Collections.Generic;
using System.Linq.Expressions;
using System.Text.Json;
using System.Text.Json.Serialization;

#nullable restore
namespace Elastic.Clients.Elasticsearch.SearchableSnapshots
{
	public sealed class SearchableSnapshotsStatsRequestParameters : RequestParameters<SearchableSnapshotsStatsRequestParameters>
	{
		[JsonIgnore]
		public Elastic.Clients.Elasticsearch.SearchableSnapshots.StatsLevel? Level { get => Q<Elastic.Clients.Elasticsearch.SearchableSnapshots.StatsLevel?>("level"); set => Q("level", value); }
	}

	public sealed partial class SearchableSnapshotsStatsRequest : PlainRequestBase<SearchableSnapshotsStatsRequestParameters>
	{
		public SearchableSnapshotsStatsRequest()
		{
		}

		public SearchableSnapshotsStatsRequest(Elastic.Clients.Elasticsearch.Indices? indices) : base(r => r.Optional("index", indices))
		{
		}

		internal override ApiUrls ApiUrls => ApiUrlsLookups.SearchableSnapshotsStats;
		protected override HttpMethod HttpMethod => HttpMethod.GET;
		protected override bool SupportsBody => false;
		[JsonIgnore]
		public Elastic.Clients.Elasticsearch.SearchableSnapshots.StatsLevel? Level { get => Q<Elastic.Clients.Elasticsearch.SearchableSnapshots.StatsLevel?>("level"); set => Q("level", value); }
	}

	public sealed partial class SearchableSnapshotsStatsRequestDescriptor<TDocument> : RequestDescriptorBase<SearchableSnapshotsStatsRequestDescriptor<TDocument>, SearchableSnapshotsStatsRequestParameters>
	{
		internal SearchableSnapshotsStatsRequestDescriptor(Action<SearchableSnapshotsStatsRequestDescriptor<TDocument>> configure) => configure.Invoke(this);
		public SearchableSnapshotsStatsRequestDescriptor()
		{
		}

		internal override ApiUrls ApiUrls => ApiUrlsLookups.SearchableSnapshotsStats;
		protected override HttpMethod HttpMethod => HttpMethod.GET;
		protected override bool SupportsBody => false;
		public SearchableSnapshotsStatsRequestDescriptor<TDocument> Level(Elastic.Clients.Elasticsearch.SearchableSnapshots.StatsLevel? level) => Qs("level", level);
		public SearchableSnapshotsStatsRequestDescriptor<TDocument> Indices(Elastic.Clients.Elasticsearch.Indices? indices)
		{
			RouteValues.Optional("index", indices);
			return Self;
		}

		protected override void Serialize(Utf8JsonWriter writer, JsonSerializerOptions options, IElasticsearchClientSettings settings)
		{
		}
	}

	public sealed partial class SearchableSnapshotsStatsRequestDescriptor : RequestDescriptorBase<SearchableSnapshotsStatsRequestDescriptor, SearchableSnapshotsStatsRequestParameters>
	{
		internal SearchableSnapshotsStatsRequestDescriptor(Action<SearchableSnapshotsStatsRequestDescriptor> configure) => configure.Invoke(this);
		public SearchableSnapshotsStatsRequestDescriptor()
		{
		}

		internal override ApiUrls ApiUrls => ApiUrlsLookups.SearchableSnapshotsStats;
		protected override HttpMethod HttpMethod => HttpMethod.GET;
		protected override bool SupportsBody => false;
		public SearchableSnapshotsStatsRequestDescriptor Level(Elastic.Clients.Elasticsearch.SearchableSnapshots.StatsLevel? level) => Qs("level", level);
		public SearchableSnapshotsStatsRequestDescriptor Indices(Elastic.Clients.Elasticsearch.Indices? indices)
		{
			RouteValues.Optional("index", indices);
			return Self;
		}

		protected override void Serialize(Utf8JsonWriter writer, JsonSerializerOptions options, IElasticsearchClientSettings settings)
		{
		}
	}
}